package com.ruoyi.school.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 见习实习
 * @TableName pac_internship
 */
@TableName(value ="pac_internship")
@Data
public class PacInternship implements Serializable {
    /**
     * 主键ID
     */
    @TableId(type = IdType.AUTO)
    private Integer id;

    /**
     * 学生ID
     */
    private Long stuId;

    /**
     * 实习开始时间
     */
    private Date startTime;

    /**
     * 实习结束时间
     */
    private Date endTime;

    /**
     * 实习地址
     */
    private String shipAddress;

    /**
     * 实习学期（1:上半学期 2:下半学期）
     */
    private Integer shipTerm;

    /**
     * 实习标题
     */
    private String shipTitle;

    /**
     * 实习内容
     */
    private String shipCont;

    /**
     * 实习周数
     */
    private Integer shipWeek;

    /**
     * 创建人
     */
    private String createBy;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 更新人
     */
    private String updateBy;

    /**
     * 更新时间
     */
    private Date updateTime;

    @TableField(exist = false)
    private Date shipTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PacInternship other = (PacInternship) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getStuId() == null ? other.getStuId() == null : this.getStuId().equals(other.getStuId()))
            && (this.getStartTime() == null ? other.getStartTime() == null : this.getStartTime().equals(other.getStartTime()))
            && (this.getEndTime() == null ? other.getEndTime() == null : this.getEndTime().equals(other.getEndTime()))
            && (this.getShipAddress() == null ? other.getShipAddress() == null : this.getShipAddress().equals(other.getShipAddress()))
            && (this.getShipTerm() == null ? other.getShipTerm() == null : this.getShipTerm().equals(other.getShipTerm()))
            && (this.getShipTitle() == null ? other.getShipTitle() == null : this.getShipTitle().equals(other.getShipTitle()))
            && (this.getShipCont() == null ? other.getShipCont() == null : this.getShipCont().equals(other.getShipCont()))
            && (this.getShipWeek() == null ? other.getShipWeek() == null : this.getShipWeek().equals(other.getShipWeek()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getStuId() == null) ? 0 : getStuId().hashCode());
        result = prime * result + ((getStartTime() == null) ? 0 : getStartTime().hashCode());
        result = prime * result + ((getEndTime() == null) ? 0 : getEndTime().hashCode());
        result = prime * result + ((getShipAddress() == null) ? 0 : getShipAddress().hashCode());
        result = prime * result + ((getShipTerm() == null) ? 0 : getShipTerm().hashCode());
        result = prime * result + ((getShipTitle() == null) ? 0 : getShipTitle().hashCode());
        result = prime * result + ((getShipCont() == null) ? 0 : getShipCont().hashCode());
        result = prime * result + ((getShipWeek() == null) ? 0 : getShipWeek().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", stuId=").append(stuId);
        sb.append(", startTime=").append(startTime);
        sb.append(", endTime=").append(endTime);
        sb.append(", shipAddress=").append(shipAddress);
        sb.append(", shipTerm=").append(shipTerm);
        sb.append(", shipTitle=").append(shipTitle);
        sb.append(", shipCont=").append(shipCont);
        sb.append(", shipWeek=").append(shipWeek);
        sb.append(", createBy=").append(createBy);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}